package com.hspedu.poly_;

/**
 * @Author Stringzhua
 * @Date 2024/3/2 16:09
 * description:
 */
public class Poly01 {
    public static void main(String[] args) {
        Master tom = new Master("汤姆~");
        Dog dog = new Dog("大黄~");
        Bone bone = new Bone("大棒骨~");
        tom.feed(dog, bone);

        System.out.println("==============");

        Cat cat = new Cat("小花猫~");
        Fish fish = new Fish("黄花鱼~");
        tom.feed(cat, fish);

        Pig pig = new Pig("佩奇");
        Rice rice = new Rice("米饭");
        tom.feed(pig,rice);
    }
}
